package com.example.orderserver.controller;

import com.example.orderserver.entity.Order;
import com.example.orderserver.service.IOrderService;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author whx
 * @date 2022/4/3
 */
@RestController
@AllArgsConstructor
public class OrderController {
    private final IOrderService orderService;

    @GetMapping("list")
    public List<Order> list(){
        return orderService.list();
    }

}
